(show-paren-mode 1)
(column-number-mode 1)
(electric-pair-mode t)
(setq-default  truncate-lines t)
(menu-bar-mode -1)
(tool-bar-mode -1)
(scroll-bar-mode 0)
(setq-default tab-width 4)
(fset 'yes-or-no-p 'y-or-n-p)
<<<<<<< HEAD
(tool-bar-mode 0)
(scroll-bar-mode -1)
(if (display-graphic-p)
	(load-theme 'tango)
	(load-theme 'tango-dark))
;;关闭滚动时自动跳转到屏幕中间。
(setq auto-window-vscroll nil)
(setq scroll-step 1)
(setq scroll-conservatively 10000)

(require 'recentf)
(recentf-mode 1)
(setq recentf-max-saved-items 500)
(setq inhibit-startup-screen t)

(setq create-lockfiles nil)
(setq make-backup-files nil)

(defconst emacs-tmp-dir (expand-file-name (format "emacs%d" (user-uid)) temporary-file-directory))
(unless (file-exists-p emacs-tmp-dir)
  (make-directory emacs-tmp-dir t))
(setq backup-directory-alist
	  `(("." . ,emacs-tmp-dir)))
(setq auto-save-file-name-transforms
	  `(("." ,emacs-tmp-dir t)))
(setq auto-save-list-file-prefix
	  emacs-tmp-dir)


(require 'auto-save)
(auto-save-enable)
(setq auto-save-silent t)
(setq auto-save-delete-trailing-whitespace t)

(provide 'base-init)
